import axios from "./axios"

const list = () => {
    return axios.request({
        url: "/contact/list"
    })
}
const add = (data) => {
    return axios.request({
        url: "/contact/add",
        method: "post",
        data
    })
}

const edit = (data) => {
    return axios.request({
        url: "/contact/edit",
        method: "put",
        data
    })
}
const del = (id) => {
    return axios.request({
        url: "/contact/delete/" + id,
        method: "delete"
    })
}
export default {
    list,
    add,
    del,
    edit
}
